home *** CD-ROM | disk | FTP | other *** search
/ PC World Komputer 2010 April / PCWorld0410.iso / hity wydania / Blender 2.49b / blender-2.49b-windows.exe / $_4_ / .blender / scripts / hotkeys.py < prev    next >
Text File  |  2009-08-31  |  35KB  |  945 lines

  1. #!BPY
  2. # coding: utf-8
  3. """ Registration info for Blender menus:
  4. Name: 'HotKey and MouseAction Reference'
  5. Blender: 242
  6. Group: 'Help'
  7. Tip: 'All the hotkeys/short keys'
  8. """ 
  9.  
  10. __author__ = "Jean-Michel Soler (jms)"
  11. __url__ = ("blender", "blenderartist",
  12. "Script's homepage, http://jmsoler.free.fr/didacticiel/blender/tutor/cpl_hotkeyscript.htm",
  13. "Communicate problems and errors, http://www.zoo-logique.org/3D.Blender/newsportal/thread.php?group=3D.Blender")
  14. __version__ = "21/01/2007"
  15.  
  16. __bpydoc__ = """\
  17. This script is a reference about all hotkeys and mouse actions in Blender.
  18.  
  19. Usage:
  20.  
  21. Open the script from the Help menu and select group of keys to browse.
  22.  
  23. Notes:<br>
  24.     Additional entries in the database (c) 2004 by Bart.
  25.     Additional entries in the database for blender 2.37 --> 2.43 (c) 2003-2007/01 by jms.
  26.     
  27. """
  28.  
  29. #------------------------
  30. #  Hotkeys script
  31. #        (c) jm soler (2003-->01/2007)
  32. # -----------------------
  33. # Page officielle :
  34. #   http://jmsoler.free.fr/didacticiel/blender/tutor/cpl_hotkeyscript.htm
  35. # Communiquer les problemes et les erreurs sur:
  36. #   http://www.zoo-logique.org/3D.Blender/newsportal/thread.php?group=3D.Blender
  37. #--------------------------------------------- 
  38. # ce script est proposΘ sous licence GPL pour etre associe
  39. # a la distribution de Blender 2.33 et suivant
  40. # --------------------------------------------------------------------------
  41. # this script is released under GPL licence
  42. # for the Blender 2.33 scripts package
  43. # --------------------------------------------------------------------------
  44. # ***** BEGIN GPL LICENSE BLOCK *****
  45. #
  46. # Script copyright (C) 2003, 2004: Jean-Michel Soler 
  47. # Additionnal entries in the original data base (c) 2004 by Bart (bart@neeneenee.de)
  48. #
  49. # This program is free software; you can redistribute it and/or
  50. # modify it under the terms of the GNU General Public License
  51. # as published by the Free Software Foundation; either version 2
  52. # of the License, or (at your option) any later version.
  53. #
  54. # This program is distributed in the hope that it will be useful,
  55. # but WITHOUT ANY WARRANTY; without even the implied warranty of
  56. # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  57. # GNU General Public License for more details.
  58. #
  59. # You should have received a copy of the GNU General Public License
  60. # along with this program; if not, write to the Free Software Foundation,
  61. # Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
  62. #
  63. # ***** END GPL LICENCE BLOCK *****  
  64. # --------------------------------------------------------------------------
  65.  
  66. import Blender
  67. from Blender.Draw import *
  68. from Blender.BGL import *
  69.  
  70. # INTERNATIONAL={0:'English','1':'French'}
  71. # LANGUAGE=0
  72.  
  73. hotkeys={
  74. 'Search ':[['', '']],
  75. 'Specials 1 ':[
  76. [',', 'Set Bounding Box rotation scaling pivot'],
  77. ['Ctrl-,', 'Set Median Point rotation scaling pivot'],
  78. ['.', 'Set 3D cursor as rotation scaling pivot'],
  79. ['.', 'Outliner : to get the current active data in center of view'],
  80. ['Ctrl-.', 'Set Individual Object Centers as rotation scaling pivot'],
  81. ['~', 'Display all layers (German keys: ÷,french keyboard: ∙)'],
  82. ['Shift-~', 'Display all/previous layers (German keys: Shift-÷, french keyboard: shift-∙)'],
  83. ['ENTER', 'Outliner : to open a subtree, works on entire item line. '],    
  84. ['HOME', 'Outliner :  to show the entire Object hierarchy. '],
  85. ['SHIFT+BACKSPACE',' Text edit mode: Clear text '],
  86. ['SPACE', 'Popup menu'],
  87. ['SPACE', '3D View: camera selected'],
  88. ['Ctrl-SPACE', 'Manipulator (transform widget) Menu'],
  89. ['TAB', 'Enter/exit Edit Mode'],
  90. ['TAB', 'Edit Mode and Numerical Edit (see N key) : move to next input value'],
  91. ['TAB', 'Sequencer: Edit meta strip'],
  92. ['TAB', 'IPO: Edit selected'],
  93. ['TAB', 'Text Editor : indent'],
  94. ['TAB', 'NODE window : Edit group'], #243    
  95. ['Shift-TAB', 'Text Editor : unindent'],
  96. ['Shift-TAB', 'Edit Mode: Toggle snaping'],
  97. ['Ctrl-TAB', 'ARMATURE : Enter/exit Pose Mode'],
  98. ['Ctrl-TAB','MESH : all views, enter exit weight paint mode.'],
  99. ['Shift-TAB', 'Edit Mode : Enter Object Mode'],
  100. ['Ctrl-Open menu /', ''],
  101. ['Ctrl-Load Image', 'Opens a thumbnail browser instead of file browser for images'],
  102. ['.', '...']
  103. ],
  104.  
  105. 'Mouse ':[
  106. ['Actions:', ''],
  107. ['LMB', '3D View: Set 3D Cursor'],
  108. ['LMB', '3D View: camera selected'],
  109. ['LMB drag', 'Border select circle: add to selection'],
  110. ['LMB hold down', 'Popup menu'],
  111. ['LMB hold down drag', 'Gesture'],
  112. ['Ctrl-LMB', 'IPO: Add key'],
  113. ['Ctrl-LMB', '3D View: OBJECT or EDIT mode, select with the Lasso tool'],
  114. ['Ctrl-LMB', '3D View: ARMATURE EDIT mode, add a new bone to the selected end '],
  115. ['Shift-LMB','MANIPULATOR (transform widget): select the axe to remove in the current'],
  116. ['Shift-LMB','MANIPULATOR      transformation ( if there is a problem with small step adjustment'], 
  117. ['Shift-LMB','MANIPULATOR      first select the axe or axes with LBM alone)'],
  118. ['Shift-LMB', 'Outliner : Hold Shift while clicking on a triangle arrow to open/close the subtree below'],
  119. ['MMB', 'Rotate'],
  120. ['Ctrl-MMB', 'Zoom view'],
  121. ['Ctrl-LMB', 'Outliner : Hold CTRL while clicking on a name allows you to edit a name.'],
  122. ['Ctrl-LMB', 'Outliner :      This works for all visualized data, including bones or vertex groups,'],
  123. ['Ctrl-LMB', 'Outliner :      but not for \'nameless\' items that draw the links to Hooks, Deform '],
  124. ['Ctrl-LMB', 'Outliner :   Groups or Constraints.'],
  125. ['Shift-MMB', 'Move view'],
  126. ['RMB', 'Select'],
  127. ['RMB drag', 'Border select circle: subtract from selection'],
  128. ['RMB hold down', 'Popup menu'],
  129. ['Alt-RMB', 'Object Mode :Select but in a displayed list of objects located under the mouse cursor'],
  130. ['Alt-RMB', 'Edit Mode: Select EDGES LOOP '],
  131. ['Alt-Ctrl-RMB', 'Edit Mode: Select FACES LOOP'],    
  132. ['Alt-Ctrl-RMB', 'UV Image Editor: Select face'],
  133. ['Shift-RMB', 'Add/subtract to/from selection'],
  134. ['Wheel', 'Zoom view'],
  135. ['Transformations:', ''],
  136. ['Drag+Ctrl', 'Step adjustment'],
  137. ['Drag+Ctrl-Shift', 'Small step adjustment (Transform Widget : first select the axe or axes with LBM alone)'],
  138. ['Drag+Shift', 'Fine adjustment (Transform Widget : first select the axe or axes with LBM alone)'],
  139. ['LMB', 'Confirm transformation'],
  140. ['MMB', 'Toggle optional transform feature'],
  141. ['RMB', 'Abort transformation'],
  142. ['LMB', 'Grease Pencil: when "Draw Mode On", draw new stroke'],
  143. ['RMB', 'Grease Pencil: when "Draw Mode On", eraser tool for stroke segments'],
  144. ['Shift-LMB', 'Grease Pencil: draw new stroke'],
  145. ['Alt-RMB', 'Grease Pencil: eraser tool for stroke segments'],
  146. ['.', '...']
  147. ],
  148.  
  149. 'F-Keys ':[
  150. ['F1', 'Open File'],
  151. ['Shift-F1', 'Library Data Select'],
  152. ['F2', 'Save File'],
  153. ['Shift-F2', 'Export DXF'],
  154. ['Ctrl-F2', 'Save/export in vrml 1.0 format' ],
  155. ['F3', 'Save image'],
  156. ['Ctrl-F3', 'Save image : dump 3d view'],
  157. ['Ctrl-Shift-F3', 'Save image : dump screen'],
  158. ['F4', 'Logic Window (may change)'],
  159. ['Shift-F4', 'Object manager Data Select '],
  160. ['F5', 'Material Window'],
  161. ['Shift-F5', '3D Window'],
  162. ['F6', 'Texture Window'],
  163. ['Shift-F6', 'IPO Window'],
  164. ['F7', 'Object Window'],
  165. ['Shift-F7', 'Buttons Window'],
  166. ['F8', 'World Window'],
  167. ['Shift-F8', 'Video Sequencer Window'],
  168. ['F9', 'Edit Mode Window'],
  169. ['Shift-F9', 'OOP Window'],
  170. ['Alt-Shift-F9', 'OutLiner Window'],
  171. ['F10', 'Render Window'],
  172. ['Shift-F10', 'UV Image Editor'],
  173. ['F11', 'Recall the last rendered image'],
  174. ['Shift-F11', 'Text Editor'],
  175. ['ctrl-F11', 'replay the last rendered animation'],
  176. ['F12', 'Render current Scene'],
  177. ['Ctrl-F12', 'Render animation'],
  178. ['Ctrl-Shift-F12', 'NLA Editor'],
  179. ['Shift-F12', 'Action Editor'],
  180. ['Shift-F12', 'Action Editor'],
  181. ['.', '...']
  182. ],
  183.  
  184. 'Numbers ':[
  185. ['1..2..0-=', 'Show layer 1..2..12'],
  186. ['1..2..0-=', 'Edit Mode with Size, Grab, rotate tools : enter value'],
  187. ['Alt-1..2..0', 'Show layer 11..12..20'],
  188. ['Shift-1..2..0', 'Toggle layer 1..2..12'],
  189. ['Ctrl-1..4', 'Object/Edit Mode : change subsurf level to the selected value'],
  190. ['Shift-ALT-...', 'Toggle layer 11..12..20'],
  191. ['Crtl-Shift-ALT-3', 'Edit Mode & Face Mode : Triangle faces'],
  192. ['Crtl-Shift-ALT-4', 'Edit Mode & Face Mode : Quad faces'],
  193. ['Crtl-Shift-ALT-5', 'Edit Mode & Face Mode : Non quad or triangle faces'],
  194. ['.', '...']
  195. ],
  196.  
  197. 'Numpad ':[
  198. ['Numpad DEL', 'Zoom on object'],
  199. ['Numpad /', 'Local view on object (hide others)'],
  200. ['Numpad *', 'Rotate view to objects local axes'],
  201. ['Numpad +', 'Zoom in (works everywhere)'],
  202. ['Numpad -', 'OutLiner window, Collapse one level of the  hierarchy'],
  203. ['Alt-Numpad +', 'Proportional vertex Edit Mode: Increase range of influence'],
  204. ['Ctrl-Numpad +', 'Edit Mode: Select More vertices'],
  205. ['Numpad -', 'Zoom out (works everywhere)'],
  206. ['Numpad +', 'OutLiner window, Expand one level of the  hierarchy'],
  207. ['Alt-Numpad -', 'Proportional vertex Edit Mode: Decrease range of influence'],
  208. ['Ctrl-Numpad +', 'Edit Mode: Select Less vertices'],
  209. ['Numpad 0', 'Set Camera view'],
  210. ['Ctrl-Numpad 0', 'Set active object as camera'],
  211. ['Alt-Numbad 0', 'Restore old camera'],
  212. ['Ctrl-Alt-Numpad 0', 'Align active camera to view'],
  213. ['Numpad 1', 'Front view'],
  214. ['Ctrl-Numpad 1', 'Back view'],
  215. ['Numpad 3', 'Right view'],
  216. ['Ctrl-Numpad 3', 'Left view'],
  217. ['Numpad 7', 'Top view'],
  218. ['Ctrl-Numpad 7', 'Bottom view '],
  219. ['Numpad 5', 'Toggle orthogonal/perspective view'],
  220. ['Numpad 9', 'Redraw view'],
  221. ['Numpad 4', 'Rotate view left'],
  222. ['ctrl-Shift-Numpad 4', 'Previous Screen'],
  223. ['Numpad 6', 'Rotate view right'],
  224. ['ctrl-Shift-Numpad 6', 'Next Screen'],
  225. ['Numpad 8', 'Rotate view up'],
  226. ['Numpad 2', 'Rotate view down'],
  227. ['.', '...']
  228. ],
  229.  
  230. 'Arrows ':[
  231. ['Home/Pos1', 'View all',''],
  232. ['Home', 'OutLiner Windows, Show hierarchy'],
  233. ['PgUp', 'Edit Mode and Proportionnal Editing Tools, increase influence'],
  234. ['PgUp', 'Strip Editor, Move Down'],
  235. ['PgUp', 'TimeLine: Jump to next marker'],
  236. ['PgUp', 'IPO: Select next keyframe'],
  237. ['Ctrl-PgUp', 'IPO: Select and jump to next keyframe'],
  238. ['Ctrl-PgUn', 'TimeLine: Jump to next key'],    
  239. ['PgDn', 'Edit Mode and Proportionnal Editing Tools, decrease influence'],
  240. ['PgDn', 'Strip Editor, Move Up'],
  241. ['PgDn', 'TimeLine: Jump to prev marker'],
  242. ['PgDn', 'IPO: Select previous keyframe'],
  243. ['Ctrl-PgDn', 'IPO: Select and jump to previous keyframe'],
  244. ['Ctrl-PgDn', 'TimeLine: Jump to prev key'],        
  245. ['Left', 'One frame backwards'],
  246. ['Right', 'One frame forwards'],
  247. ['Down', '10 frames backwards'],
  248. ['Up', '10 frames forwards'],
  249. ['Alt-Down', 'Blender in Window mode'],
  250. ['Alt-Up', 'Blender in Fullscreen mode'],
  251. ['Ctrl-Left', 'Previous screen'],
  252. ['Ctrl-Right', 'Next screen'],
  253. ['Ctrl-Down', 'Maximize window toggle'],
  254. ['Ctrl-Up', 'Maximize window toggle'],
  255. ['Shift-Arrow', 'Toggle first frame/ last frame'],
  256. ['.', '...']
  257. ],
  258.  
  259. 'Letters ':[ 
  260. {
  261. "A":[ 
  262. ['A', 'Select all/Deselect all'],
  263. ['A', 'Outliner : Select all/Deselect all'],
  264. ['A', 'Ipo Editor : Object mode, Select all/Deselect all displayed Curves'],  #243
  265. ['A', 'Ipo Editor : Edit mode, Select all/Deselect all vertices'], #243
  266. ['A', 'Render window (F12) : Display alpha plane'],
  267. ['Alt-A', 'Play animation in current window'],
  268. ['Ctrl-A', 'Apply objects size/rotation to object data'],
  269. ['Ctrl-A', 'Text Editor: Select all'],
  270. ['Ctrl-ALT-A', '3D-View: Armature Edit mode, align selected bones to active bone'],
  271. ['Shift-A', 'Sequencer: Add menu'],
  272. ['Shift-A', '3D-View: Add menu'],
  273. ['Shift-A', 'Sculpt Mode: Keep the brush center anchored to the initial location'],
  274. ['Shift-ALT-A', 'Play animation in all windows'],
  275. ['Shift-CTRL-A', 'Apply lattice / Make dupliverts real'],
  276. ['Shift-CTRL-A', 'Apply Deform '],
  277. ['.', '...']
  278. ],
  279.  
  280. "B":[ 
  281. ['B', 'Border select'],
  282. ['BB', 'Circle select'],
  283. ['Alt-B', 'Object Mode: Select visible view section in 3D space'],
  284. ['Shift-B', 'Set render border (in active camera view)'],
  285. ['Ctrl-Alt-B', 'Object Mode: in 3D view, Bake (on an image in the uv editor window) the selected Meshes'], #243
  286. ['Ctrl-Alt-B', 'Object Mode: in 3D view, Bake Full render of selected Meshes'],     #243
  287. ['Ctrl-Alt-B', 'Object Mode: in 3D view, Bake Ambient Occlusion of selected Meshes'],  #243    
  288. ['Ctrl-Alt-B', 'Object Mode: in 3D view, Bake Normals of the selected Meshes'],     #243
  289. ['Ctrl-Alt-B', 'Object Mode: in 3D view, Bake Texture Only of selected Meshes'],    #243
  290. ['.', '...']
  291. ],
  292.  
  293. "C":[ 
  294. ['C', 'Center view on cursor'],
  295. ['C', 'UV Image Editor: Active Face Select toggle'],
  296. ['C', 'Sequencer: Change content of the strip '], #243
  297. ['C', 'IPO: Snap current frame to selected key'],
  298. ['C', 'TimeLine: Center View'],    
  299. ['C', 'File Selector : Copy file'],
  300. ['C', 'NODE window : Show cyclic referencies'], #243                
  301. ['Alt-C', 'Object Mode: Convert menu'],
  302. ['Alt-C', 'Text Editor: Copy '],
  303. ['Ctrl-Alt-C', 'Object Mode : Add  Constraint'],
  304. ['Ctrl-Shift-C', 'Text Editor: Copy selection to clipboard'],
  305. ['Ctrl-C', 'Copy menu (Copy properties of active to selected objects)'],
  306. ['Ctrl-C', 'UV Image Editor: Stick UVs to mesh vertex'],
  307. ['Ctrl-C','ARMATURE : posemode, Copy pose attributes'],
  308. ['Ctrl-Alt-C',' ARMATURE : posemode, add constraint to new empty object.'],
  309. ['Shift-C', 'Center and zoom view on selected objects'],
  310. ['Shift-C', 'UV Image Editor: Stick local UVs to mesh vertex'],
  311. ['.', '...']
  312. ],
  313.  
  314. "D":[  
  315. ['D', 'Set 3d draw mode'],
  316. ['Alt-D', 'Object Mode: Create new instance of object'],
  317. ['Ctrl-D', 'Display alpha of image texture as wire'],
  318. ['Ctrl-D', 'Text Editor : uncomment'],
  319. ['Shift-D', 'Create full copy of object'],
  320. ['Shift-D', 'NODE window : duplicate'], #243    
  321. ['CTRL-SHIFT-D', 'NLA editor : Duplicate markers'],
  322. ['CTRL-SHIFT-D', 'Action editor : Duplicate markers'],    
  323. ['CTRL-SHIFT-D', 'IPO editor : Duplicate markers'],        
  324. ['.', '...']
  325. ],
  326.  
  327. "E":[ 
  328. ['E', 'Edit Mode: Extrude'],
  329. ['E', 'UV Image Editor: LSCM Unwrap'],
  330. ['E', 'TimeLine: Set current frame as End '],    
  331. ['E', 'NODE window : Execute composite'], #243        
  332. ['ER', 'Edit Mode: Extrude Rotate'],
  333. ['ES', 'Edit Mode: Extrude Scale'],
  334. ['ESX', 'Edit Mode: Extrude Scale X axis'],
  335. ['ESY', 'Edit Mode: Extrude Scale Y axis'],
  336. ['ESZ', 'Edit Mode: Extrude Scale Z axis'],
  337. ['EX', 'Edit Mode: Extrude along X axis'],
  338. ['EY', 'Edit Mode: Extrude along Y axis'],
  339. ['EZ', 'Edit Mode: Extrude along Z axis'],
  340. ['Alt-E', 'Edit Mode: exit Edit Mode'],
  341. ['Ctrl-E', 'Edit Mode: Edge Specials menu'],
  342. ['Ctrl-E', 'Edit Mode: Edge Specials menu, Mark seams'],
  343. ['Ctrl-E', 'Edit Mode: Edge Specials menu, Clear seams'],
  344. ['Ctrl-E', 'Edit Mode: Edge Specials menu, Rotate Edge CW'],
  345. ['Ctrl-E', 'Edit Mode: Edge Specials menu, Rotate Edge CCW'],
  346. ['Ctrl-E', 'Edit Mode: Edge Specials menu, Loop Cut'],
  347. ['Ctrl-E', 'Edit Mode: Edge Specials menu, Edge Slide'],
  348. ['Shift-E', 'Edit Mode: SubSurf Edge Sharpness'],
  349. ['.', '...']
  350. ],
  351.  
  352. "F":[ 
  353. ['F', 'Edit mode: Make edge/face'],
  354. ['F', 'Sequencer: Set Filter Y'],
  355. ['F', 'Object Mode: UV/Face Select mode'],
  356. ['Alt-F', 'Edit Mode: Beautify fill'],
  357. ['Alt-F,','Text editor : find again '],
  358. ['Alt-Ctrl-F,','Text editor : find '],
  359. ['Ctrl-F', 'Object Mode: Sort faces in Z direction'],
  360. ['Ctrl-F', 'Edit Mode: Flip triangle edges'],
  361. ['Shift-F', 'Edit Mode: Fill with triangles'],
  362. ['Shift-F', 'Object Mode: fly mode (see header for fly mode keys)'],
  363. ['.', '...']
  364. ],
  365.  
  366. "G":[ 
  367. ['G', 'Grab (move)'],
  368. ['G', 'Timeline : Grab (move) Marker'],
  369. ['Alt-G', 'Clear location (this does only make sense in Object mode)'],
  370. ['Alt-G', 'NODE window : ungroup'], #243
  371. ['Shift-ALT-G', 'Object mode: Remove selected objects from group'],
  372. ['Ctrl-G', 'NODE window : group'], #243    
  373. ['Ctrl-G', 'Add selected objects to group'],
  374. ['Ctrl-G', 'IPO editor, Grab/move marker'],
  375. ['Ctrl-Alt-G', 'MANIPULATOR (transform widget): set in Grab Mode'],
  376. ['Shift-G', 'Object mode: Selected Group menu'],
  377. ['Shift-G', 'Object mode: Selected Group menu 1, Children'],
  378. ['Shift-G', 'Object mode: Selected Group menu 2, Immediate Children'],
  379. ['Shift-G', 'Object mode: Selected Group menu 3, Parent'],
  380. ['Shift-G', 'Object mode: Selected Group menu 4, Sibling'],
  381. ['Shift-G', 'Object mode: Selected Group menu 5, Object of same type'],
  382. ['Shift-G', 'Object mode: Selected Group menu 6, Object in same shared layers'],
  383. ['Shift-G', 'Object mode: Selected Group menu 7, Objects in same group'],
  384. ['.', '...']
  385. ],
  386.  
  387. "H":[ 
  388. ['H', 'Hide selected vertices/faces'],
  389. ['H', 'Curves: Set handle type'],
  390. ['H', 'Action editor: Handle type aligned'],
  391. ['H', 'Action editor: Handle type free'],        
  392. ['H', 'NODE window : hide/unhide'], #243        
  393. ['Alt-H', 'Edit Mode : Show Hidden vertices/faces'],
  394. ['Shift-H', 'Curves: Automatic handle calculation'],
  395. ['Shift-H', 'Action editor: Handle type auto'],    
  396. ['Shift-H', 'Edit Mode : Hide deselected  vertices/faces'],
  397. ['Ctrl-H', 'Edit Mode : Add a hook on selected points or show the hook menu .'],
  398. ['.', '...']
  399. ],
  400.  
  401. "I":[ 
  402. ['I', 'Insert Keyframe menu'],
  403. ['Alt-I','Delete Keyframe menu'],
  404. ['Ctrl-I','Select Inverse'],
  405. ['Shift-I','ARMATURE : add IK constraint'],
  406. ['Ctrl-Alt-I','ARMATURE : posemode, remove IK constraints.'],
  407. ['.', '...']
  408. ],
  409.  
  410. "J":[ 
  411. ['J', 'IPO: Join menu'],
  412. ['J', 'Mesh: Join all adjacent triangles to quads'],  
  413. ['J', 'Render Window: Swap render buffer'],
  414. ['Alt-J,','Text editor : Jump '],
  415. ['Ctrl-J', 'Join selected objects'],
  416. ['Ctrl-J', 'Nurbs: Add segment'],
  417. ['Ctrl-J', 'IPO: Join keyframes menu'],
  418. ['.', '...']
  419. ],
  420.  
  421. "K":[  
  422. ['K', '3d Window: Show keyframe positions'],
  423. ['K', 'Edit Mode: Loop/Cut menu'],
  424. ['K', 'IPO: Show keyframe positions'],
  425. ['K', 'Nurbs: Print knots'],
  426. ['K', 'VIDEO editor : cut at current frame'], #243        
  427. ['Ctrl-K', 'Make skeleton from armature'],
  428. ['Shift-K', 'Show and select all keyframes for object'],
  429. ['Shift-K', 'Edit Mode: Knife Mode select'],
  430. ['Shift-K', 'UV Face Select: Clear vertex colours'],
  431. ['Shift-K', 'Vertex Paint: All vertex colours are erased; they are changed to the current drawing colour.'],
  432. ['.', '...']
  433. ],
  434.  
  435. "L":[ 
  436. ['L', 'Make local menu'],
  437. ['L', 'Edit Mode: Select linked vertices (near mouse pointer)'],
  438. ['L', 'NODE window: Select linked from '], #243    
  439. ['L', 'OOPS window: Select linked objects'],
  440. ['L', 'UV Face Select: Select linked faces'],
  441. ['Ctrl-L', 'Make links menu (for instance : to scene...)'],
  442. ['Shift-L', 'Select links menu'],
  443. ['Shift-L', 'NODE window: Select linked to '], #243
  444. ['Ctrl-L', 'POSELIB: browse poses'],
  445. ['Shift-L', 'POSELIB: add/replace pose'],
  446. ['Ctrl-Shift-L', 'POSELIB: rename pose'],
  447. ['Alt-L', 'POSELIB: remove pose'],
  448. ['.', '...']
  449. ],
  450.  
  451. "M":[ 
  452. ['M', 'Object mode : Move object to different layer'],
  453. ['M', 'Sequencer: Make meta strip (group) from selected strips'],
  454. ['M', 'Edit Mode: Mirros Axis menu'],
  455. ['M', 'File Selector: rename file'],
  456. ['M', 'Video Sequence Editor : Make Meta strip...'],        
  457. ['M', 'NLA editor: Add marker'],    
  458. ['M', 'Action editor: Add marker'],        
  459. ['M', 'IPO editor: Add marker'],    
  460. ['M', 'TimeLine: Add marker'],    
  461. ['Alt-M', 'Edit Mode: Merge vertices menu'],
  462. ['Alt-M', 'Video Sequence Editor : Separate Meta strip...'],    
  463. ['Ctrl-M', 'Object Mode: Mirros Axis menu'],
  464. ['Shift-M', 'TimeLine: Name marker'],
  465. ['Shift-M', 'IPO editor : Name marker'],
  466. ['Shift-M', 'NLA editor : Name marker'],
  467. ['Shift-M', 'Actions editor : Name marker'],    
  468. ['.', '...']
  469. ],
  470.  
  471. "N":[ 
  472. ['N', 'Transform Properties panel'] ,
  473. ['N', 'OOPS window: Rename object'],
  474. ['N', 'VIDEO SEQUENCE editor : display strip properties '], #243    
  475. ['Alt-N', 'Text Editor : New text '],
  476. ['Ctrl-N', 'Armature: Recalculate bone roll angles'] ,
  477. ['Ctrl-N', 'Edit Mode: Recalculate normals to outside'] ,
  478. ['Ctrl-Shift-N', 'Edit Mode: Recalculate normals to inside'],
  479. ['.', '...']
  480. ],
  481.  
  482. "O":[ 
  483. ['O', 'Edit Mode/UV Image Editor: Toggle proportional vertex editing'],
  484. ['O', 'IPO editor: Clean ipo curves (beware to the thresold needed value)'], #243
  485. ['Alt-O', 'Clear object origin'],
  486. ['Alt-O', 'Edit mode, 3dview with prop-edit-mode, enables/disables connected'],
  487. ['Alt-O', 'Text Editor : Open file '],
  488. ['Ctrl-O', 'Open a panel with the ten most recent projets files'], #243
  489. ['Shift-O', 'Proportional vertex Edit Mode: Toggle smooth/steep falloff'],
  490. ['Shift-O', 'Object Mode: Add a subsurf modifier to the selected mesh'],
  491. ['Shift-O', 'IPO editor: Smooth ipo curves'],    #243
  492. ['.', '...']
  493. ],
  494.  
  495. "P":[ 
  496. ['P', 'Object Mode: Start realtime engine'],
  497. ['P', 'Edit mode: Seperate vertices to new object'],
  498. ['Shift-P', 'Edit mode: Push-Pull'],
  499. ['Shift-P', 'Object mode: Add a preview window in the D window'],
  500. ['P', 'UV Image Editor:  Pin selected vertices. Pinned vertices will stay in place on the UV editor when executing an LSCM unwrap.'],
  501. ['Alt-P', 'Clear parent relationship'],
  502. ['Alt-P', 'UV Image Editor: Unpin UVs'],
  503. ['Alt-P', 'Text Editor : Run current script '],
  504. ['Ctrl-P', 'Make active object parent of selected object'],
  505. ['Ctrl-Shift-P', 'Make active object parent of selected object without inverse'],
  506. ['Ctrl-P', 'Edit mode: Make active vertex parent of selected object'],
  507. ['Ctrl-P', 'ARMATURE : editmode, make bone parent.'],
  508. ['Ctrl-Alt-P', 'ARMATURE: edimode, separate bones to new object'],
  509. ['.', '...']
  510. ],
  511.  
  512. "Q":[['Ctrl-Q', 'Quit'],
  513.      ['.', '...']
  514.      ],
  515.  
  516. "R":[ 
  517. ['R', 'FileSelector : remove file'],    
  518. ['R', 'Rotate'],
  519. ['R', 'IPO: Record mouse movement as IPO curve'],
  520. ['R', 'UV Face Select: Rotate menu uv coords or vertex colour'],
  521. ['R', 'NODE window : read saved render result'], #243    
  522. ['R', 'SEQUENCER window : re-assign entries to another strip '], #243            
  523. ['RX', 'Rotate around X axis'],
  524. ['RXX', "Rotate around object's local X axis"],
  525. ['RY', 'Rotate around Y axis'],
  526. ['RYY', "Rotate around object's local Y axis"],
  527. ['RZ', 'Rotate around Z axis'],
  528. ['RZZ', "Rotate around object's local Z axis"],
  529. ['Alt-R', 'Clear object rotation'],
  530. ['Alt-R', 'Text editor : reopen text.'],
  531. ['Ctrl-R', 'Edit Mode: Knife, cut selected edges, accept left mouse/ cancel right mouse'],
  532. ['Ctrl-Alt-R', 'MANIPULATOR (transform widget): set in Rotate Mode'],
  533. ['Shift-R', 'Edit Mode: select Face Loop'],
  534. ['Shift-R', 'Nurbs: Select row'],
  535. ['.', '...']
  536. ],
  537.  
  538. "S":[ 
  539. ['S', 'Scale'] ,
  540. ['S', 'TimeLine: Set Start'],
  541. ['SX', 'Flip around X axis'] ,
  542. ['SY', 'Flip around Y axis'] ,
  543. ['SZ', 'Flip around Z axis'] ,
  544. ['SXX', 'Flip around X axis and show axis'] ,
  545. ['SYY', 'Flip around Y axis and show axis'] ,
  546. ['SZZ', 'Flip around Z axis and show axis'] ,
  547. ['Alt-S', 'Edit mode: Shrink/fatten (Scale along vertex normals)'] ,
  548. ['Alt-S', 'Text Editor : Save the current text to file '],
  549. ['Alt-S',' ARMATURE : posemode editmode: Scale envalope.'],
  550. ['Ctrl-Shift-S', 'Edit mode: To Sphere'] ,
  551. ['Ctrl-Alt-Shift-S', 'Edit mode: Shear'] ,
  552. ['Alt-S', 'Clear object size'] ,
  553. ['Ctrl-S', 'Edit mode: Shear'] ,
  554. ['Alt-Shift-S,','Text editor : Select the line '],
  555. ['Ctrl-Alt-G', 'MANIPULATOR (transform widget): set in Size Mode'],
  556. ['Shift-S', 'Cursor/Grid snap menu'],
  557. ['Shift-S', 'Sculpt Mode: Smooth Stroke.'],
  558. ['Shift-S+1', 'VIDEO SEQUENCE editor : jump to the current frame '],
  559. ['.', '...']
  560. ],
  561.  
  562. "T":[ 
  563. ['T', 'Adjust texture space'],
  564. ['T', 'Edit mode: Flip 3d curve'],
  565. ['T', 'IPO: Menu Change IPO type, 1 Constant'],
  566. ['T', 'IPO: Menu Change IPO type, 2 Linear'],
  567. ['T', 'IPO: Menu Change IPO type, 3 Bezier'],    
  568. ['T', 'TimeLine: Show second'],    
  569. ['T', 'VIDEO SEQUENCE editor : toggle between show second andd show frame'], #243    
  570. ['Alt-T', 'Clear tracking of object'],
  571. ['Ctrl-T', 'Make selected object track active object'],
  572. ['Ctrl-T', 'Edit Mode: Convert to triangles'],
  573. ['Ctrl-Alt-T', 'Benchmark'],
  574. ['.', '...']
  575. ],
  576.  
  577. "U":[ 
  578. ['U', 'Make single user menu (for import completly linked object to another scene  for instance) '] ,
  579. ['U', '3D View: Make Single user Menu'] ,
  580. ['U', 'UV Face Select: Automatic UV calculation menu'] ,
  581. ['U', 'Vertex-/Weightpaint mode: Undo'] ,
  582. ['Ctrl-U', 'Save current state as user default'],
  583. ['Shift-U', 'Edit Mode: Redo Menu'],
  584. ['Alt-U', 'Edit Mode & Object Mode: Undo Menu'],
  585. ['.', '...']
  586. ],
  587.  
  588. "V":[ 
  589. ['V', 'Curves/Nurbs: Vector handle'],
  590. ['V', 'Edit Mode : Rip selected vertices'],
  591. ['V', 'Vertexpaint mode'],
  592. ['V', 'UV Image Editor: Stitch UVs'],
  593. ['Ctrl-V',' UV Image Editor:  maximize stretch.'],
  594. ['V', 'Action editor: Vector'],
  595. ['Alt-V', "Scale object to match image texture's aspect ratio"],
  596. ['Alt-V', 'Text Editor : Paste '],
  597. ['Alt-Shift-V', 'Text Editor : View menu'],
  598. ['Alt-Shift-V', 'Text Editor : View menu 1, Top of the file '],
  599. ['Alt-Shift-V', 'Text Editor : View menu 2, Bottom of the file '],
  600. ['Alt-Shift-V', 'Text Editor : View menu 3, PageUp'],
  601. ['Alt-Shift-V', 'Text Editor : View menu 4, PageDown'],
  602. ['Ctrl-Shift-V', 'Text Editor: Paste from clipboard'],
  603. ['Shift-V', 'Edit mode: Align view to selected vertices'],
  604. ['Shift-V', 'UV Image Editor: Limited Stitch UVs popup'],
  605. ['.', '...']  
  606. ],
  607.  
  608. "W":[ 
  609. ['W', 'Edit Mode: Specials menu'],
  610. ['W', 'Edit Mode: Specials menu, ARMATURE 1 Subdivide'],
  611. ['W', 'Edit Mode: Specials menu, ARMATURE 2 Subdivide Multi'],
  612. ['W', 'Edit Mode: Specials menu, ARMATURE 3 Switch Direction'],
  613. ['W', 'Edit Mode: Specials menu, ARMATURE 4 Flip Left-Right Name'],
  614. ['W', 'Edit Mode: Specials menu, ARMATURE 5 AutoName Left-Right'],
  615. ['W', 'Edit Mode: Specials menu, ARMATURE 6 AutoName Front-Back'],
  616. ['W', 'Edit Mode: Specials menu, ARMATURE 7 AutoName Top-Bottom'],
  617. ['W', 'Edit Mode: Specials menu, CURVE 1 Subdivide'],
  618. ['W', 'Edit Mode: Specials menu, CURVE 2 Swich Direction'],
  619. ['W', 'Edit Mode: Specials menu, CURVE 3 Set Goal Weight'],
  620. ['W', 'Edit Mode: Specials menu, CURVE 4 Set Radius'],
  621. ['W', 'Edit Mode: Specials menu, CURVE 5 Smooth'],
  622. ['W', 'Edit Mode: Specials menu, CURVE 6 Smooth Radius'],
  623. ['W', 'Edit Mode: Specials menu, MESH 1 Subdivide'],
  624. ['W', 'Edit Mode: Specials menu, MESH 2 Subdivide Multi'],
  625. ['W', 'Edit Mode: Specials menu, MESH 3 Subdivide Multi Fractal'],
  626. ['W', 'Edit Mode: Specials menu, MESH 4 Subdivide Smooth'],
  627. ['W', 'Edit Mode: Specials menu, MESH 5 Merge'],
  628. ['W', 'Edit Mode: Specials menu, MESH 6 Remove Double'],
  629. ['W', 'Edit Mode: Specials menu, MESH 7 Hide'],
  630. ['W', 'Edit Mode: Specials menu, MESH 8 Reveal'],
  631. ['W', 'Edit Mode: Specials menu, MESH 9 Select Swap'],
  632. ['W', 'Edit Mode: Specials menu, MESH 10 Flip Normal'],
  633. ['W', 'Edit Mode: Specials menu, MESH 11 Smooth'],
  634. ['W', 'Edit Mode: Specials menu, MESH 12 Bevel'],
  635. ['W', 'Edit Mode: Specials menu, MESH 13 Set Smooth'],
  636. ['W', 'Edit Mode : Specials menu, MESH 14 Set Solid'],
  637. ['W', 'Object Mode : on MESH objects, Boolean Tools menu'],
  638. ['W', 'Object Mode : on MESH objects, Boolean Tools 1 Intersect'],
  639. ['W', 'Object Mode : on MESH objects, Boolean Tools 2 union'],
  640. ['W', 'Object Mode : on MESH objects, Boolean Tools 3 difference'],
  641. ['W', 'Object Mode : on MESH objects, Boolean Tools 4 Add an intersect Modifier'],
  642. ['W', 'Object Mode : on MESH objects, Boolean Tools 5 Add an union Modifier'],
  643. ['W', 'Object Mode : on MESH objects, Boolean Tools 6 Add a difference Modifier'],
  644. ['W', 'Object mode : on TEXT object, Split characters, a new TEXT object by character in the selected string '],
  645. ['W', 'UV Image Editor: Weld/Align'],
  646. ['WX', 'UV Image Editor: Weld/Align X axis'],
  647. ['WY', 'UV Image Editor: Weld/Align Y axis'],
  648. ['Ctrl-W', 'Save current file'] ,
  649. ['Shift-W', 'Warp/bend selected vertices around cursor'],
  650. ['.', '...']
  651.  ],
  652.  
  653. "X":[ 
  654. ['X', 'Delete menu'] ,
  655. ['X', 'TimeLine : Remove marker'],
  656. ['X', 'NLA : Remove marker'],
  657. ['X', 'IPO : Remove marker'],    
  658. ['X', 'NODE window : delete'], #243        
  659. ['Alt-X', 'Text Editor : Cut '],
  660. ['Alt-X', 'Grease Pencil: Delete menu'],
  661. ['Ctrl-X', 'Restore default state (Erase all)'],
  662. ['.', '...']
  663.  ],
  664.  
  665. "Y":[ 
  666. ['Y', 'Edit Mode & Mesh : Split selected vertices/faces from the rest'],
  667. ['Ctrl-Y', 'Object Mode : Redo'],
  668. ['.', '...']
  669. ],
  670.  
  671. "Z":[ 
  672. ['Z', 'Render Window: 200% zoom from mouse position'],
  673. ['Z', 'Switch 3d draw type : solide/ wireframe (see also D)'],
  674. ['Alt-Z', 'Switch 3d draw type : solid / textured (see also D)'],
  675. ['Alt-Z,','Text editor : undo '],
  676. ['Ctrl-Z', 'Object Mode : Undo'],
  677. ['Ctrl-Z,','Text editor : undo '],
  678. ['Ctrl-Shift-Z,','Text editor : Redo '],
  679. ['Shift-Z', 'Switch 3d draw type : shaded / wireframe (see also D)'],
  680. ['.', '...']
  681. ]}]}
  682.  
  683. up=128
  684. down=129
  685. UP=0
  686. SEARCH=131
  687. OLDSEARCHLINE=''
  688. SEARCHLINE=Create('')
  689. LINE=130
  690. FINDED=[]
  691. LEN=0
  692.  
  693. for k in hotkeys.keys():
  694.    hotkeys[k].append(Create(0))
  695.  
  696. for k in hotkeys['Letters '][0]:
  697.    hotkeys['Letters '][0][k].append(Create(0))
  698.  
  699. hotL=hotkeys['Letters '][0].keys()
  700. hotL.sort()
  701.  
  702. hot=hotkeys.keys()
  703. hot.sort()
  704.  
  705. def searchfor(SEARCHLINE):
  706.     global hotkeys, hot
  707.     FINDLIST=[]
  708.     for k in hot:
  709.         if k not in ['Letters ', 'Search '] :
  710.             for l in hotkeys[k][:-1]:
  711.                 #print 'k, l : ', k,  l, l[1] 
  712.                 if  l[1].upper().find(SEARCHLINE.upper())!=-1:
  713.                     FINDLIST.append(l)
  714.                     
  715.         elif k == 'Letters ':
  716.             for l in hotL :
  717.                 for l0 in hotkeys['Letters '][0][l][:-1]:
  718.                     #print 'k, l : ',l,  k,  l0
  719.                     if l0[1].upper().find(SEARCHLINE.upper())!=-1:
  720.                         FINDLIST.append(l0)
  721.     #print 'FINDLIST',FINDLIST                    
  722.     FINDLIST.append(['Find list','Entry'])
  723.     return FINDLIST            
  724.             
  725.     
  726. glCr=glRasterPos2d
  727. glCl3=glColor3f
  728. glCl4=glColor4f
  729. glRct=glRectf
  730.  
  731. cf=[0.95,0.95,0.9,0.0]
  732. c1=[0.95,0.95,0.9,0.0]
  733. c=cf
  734. r=[0,0,0,0]
  735.  
  736. def trace_rectangle4(r,c):
  737.     glCl4(c[0],c[1],c[2],c[3])
  738.     glRct(r[0],r[1],r[2],r[3])
  739.  
  740. def trace_rectangle3(r,c,c1):
  741.     glCl3(c[0],c[1],c[2])
  742.     glRct(r[0],r[1],r[2],r[3])
  743.     glCl3(c1[0],c1[1],c1[2])
  744.  
  745. def draw():
  746.     global r,c,c1,hotkeys, hot, hotL, up, down, UP, SEARCH, SEARCHLINE,LINE
  747.     global OLDSEARCHLINE, FINDED, SCROLL, LEN
  748.     size=Buffer(GL_FLOAT, 4)
  749.     glGetFloatv(GL_SCISSOR_BOX, size)
  750.     size= size.list
  751.  
  752.     for s in [0,1,2,3]: size[s]=int(size[s])
  753.  
  754.     c=[0.75,0.75,0.75,0]
  755.     c1=[0.6,0.6,0.6,0]
  756.  
  757.     r=[0,size[3],size[2],0]
  758.     trace_rectangle4(r,c)
  759.  
  760.     c=[0.64,0.64,0.64,0]
  761.     c1=[0.95,0.95,0.9,0.0]
  762.     
  763.     r=[0,size[3],size[2],size[3]-40]
  764.     trace_rectangle4(r,c)
  765.  
  766.     c1=[0.7,0.7,0.9,0.0]
  767.     c=[0.2,0.2,0.4,0.0]
  768.     c2=[0.71,0.71,0.71,0.0]     
  769.  
  770.     glColor3f(1, 1, 1)
  771.     glRasterPos2f(42, size[3]-25)
  772.  
  773.     Text("HotKey and MouseAction Reference")
  774.    
  775.     l=0
  776.     listed=0
  777.     Llisted=0
  778.     size[3]=size[3]-18
  779.  
  780.     BeginAlign()
  781.     for i, k in enumerate(hot):
  782.        hotkeys[k][-1]=Toggle(k, i+10, 78*i, size[3]-(47), 78, 24, hotkeys[k][-1].val )
  783.        l+=len(k)
  784.        if hotkeys[k][-1].val==1.0:
  785.            listed= i
  786.     EndAlign()
  787.     l=0
  788.     size[3]=size[3]-4
  789.     
  790.     if hot[listed]!='Letters ' and hot[listed]!='Search ' :
  791.        size[3]=size[3]-8
  792.        SCROLL=size[3]/21
  793.        END=-1
  794.        if SCROLL < len(hotkeys[hot[listed]][:-1]):
  795.           BeginAlign()
  796.           Button('/\\',up,4,size[3]+8,20,14,'Scroll up') 
  797.           Button('\\/',down,4,size[3]-8,20,14,'Scroll down')            
  798.           EndAlign()
  799.           if (SCROLL+UP)<len(hotkeys[hot[listed]][:-1]):
  800.              END=(UP+SCROLL)
  801.           else:
  802.              END=-1
  803.              UP=len(hotkeys[hot[listed]][:-1])-SCROLL         
  804.        else :
  805.          UP=0
  806.        for n in  hotkeys[hot[listed]][:-1][UP:END]:
  807.           if l%2==0:
  808.              r=[0,size[3]-(21*l+66),
  809.                      size[2], size[3]-(21*l+43)]
  810.              trace_rectangle4(r,c2)
  811.           glColor3f(0,0,0)
  812.           glRasterPos2f(4+8, size[3]-(58+21*l))
  813.           Text(n[0])
  814.           glRasterPos2f(4+8*15, size[3]-(58+21*l))
  815.           Text('  : '+n[1]) 
  816.           l+=1
  817.           
  818.     elif hot[listed]=='Search ' :
  819.        r=[0,size[3]-70,
  820.           size[2], size[3]-44]
  821.        trace_rectangle4(r,c2)
  822.        SEARCHLINE=String(' ', LINE, 42, size[3]-68,200,18,SEARCHLINE.val, 256,'')
  823.        if len(FINDED)>0:
  824.         LEN=len(FINDED)       
  825.         size[3]=size[3]-8
  826.         SCROLL=size[3]/21
  827.         END=-1
  828.         
  829.         if SCROLL < len(FINDED):
  830.             BeginAlign()
  831.             Button('/\\',up,4,size[3]+8,20,14,'Scroll up') 
  832.             Button('\\/',down,4,size[3]-8,20,14,'Scroll down')            
  833.             EndAlign()
  834.             if (SCROLL+UP)<len(FINDED):
  835.                END=(UP+SCROLL-1)
  836.             else:
  837.                END=-1
  838.                #UP=len(FINDED)-SCROLL
  839.         else:
  840.             UP=0         
  841.         for n in FINDED[UP:END]:
  842.              if l%2==0:
  843.                  r=[0,size[3]-(21*l+66+24),
  844.                      size[2], size[3]-(21*l+43+24)]
  845.                  trace_rectangle4(r,c2)
  846.              glColor3f(0,0,0)
  847.              glRasterPos2f(4+8, size[3]-(58+24+21*l))
  848.              Text(n[0])
  849.              glRasterPos2f(4+8*15, size[3]-(58+24+21*l))
  850.              Text('  : '+n[1]) 
  851.              l+=1
  852.     else:
  853.        BeginAlign()
  854.        for pos, k in enumerate(hotL):
  855.             hotkeys['Letters '][0][k][-1]=Toggle(k,pos+20,pos*21, size[3]-(52+18), 21, 18, hotkeys['Letters '][0][k][-1].val )
  856.             if hotkeys['Letters '][0][k][-1].val==1.0:
  857.                Llisted=pos
  858.        EndAlign()
  859.        size[3]=size[3]-8
  860.        SCROLL=(size[3]-88)/21
  861.        END=-1
  862.        if SCROLL < len(hotkeys['Letters '][0][hotL[Llisted]]):
  863.           LEN=len(hotkeys['Letters '][0][hotL[Llisted]])
  864.           BeginAlign()
  865.           Button('/\\',up,4,size[3]+8,20,14,'Scroll up, you can use arrow or page keys too ') 
  866.           Button('\\/',down,4,size[3]-8,20,14,'Scroll down,  you can use arrow or page keys too ')            
  867.           EndAlign()
  868.           if (UP+SCROLL)<len(hotkeys['Letters '][0][hotL[Llisted]]):
  869.              END=(UP+SCROLL)
  870.           else:
  871.              END=-1
  872.              UP=len(hotkeys['Letters '][0][hotL[Llisted]])-SCROLL         
  873.        else :
  874.          UP=0
  875.  
  876.        for n in hotkeys['Letters '][0][hotL[Llisted]][UP:END]:
  877.           if l%2==0:
  878.              r=[4,size[3]-(21*l+92),
  879.                      size[2], size[3]-(69+21*l+1)]
  880.              trace_rectangle4(r,c2)
  881.  
  882.           glColor3f(0.1, 0.1, 0.15)  
  883.           glRasterPos2f(4+8, (size[3]-(88+21*l))+3)
  884.           Text(n[0])
  885.           glRasterPos2f(4+8*15, (size[3]-(88+21*l))+3)
  886.           Text('  : '+n[1]) 
  887.           l+=1
  888.  
  889. def event(evt, val):
  890.     global hotkeys, UP,  SCROLL  , LEN   
  891.     if (evt== QKEY or evt== ESCKEY): 
  892.         Exit()
  893.     elif val:
  894.       if (evt== PAGEUPKEY):
  895.          if (UP+SCROLL)<LEN-5: 
  896.              UP+=5 
  897.       elif (evt== PAGEDOWNKEY):
  898.           if UP>4: 
  899.              UP-=5 
  900.       elif (evt== UPARROWKEY):
  901.           if (UP+SCROLL)<LEN-1: 
  902.              UP+=1
  903.       elif (evt== DOWNARROWKEY):
  904.           if UP>0: 
  905.               UP-=1
  906.       Redraw()
  907.  
  908. def bevent(evt):
  909.     global hotkeysmhot, hotL, up,down,UP, FINDED
  910.     global SEARCH, SEARCHLINE,LINE, OLDSEARCHLINE
  911.  
  912.     if   (evt== 1):
  913.         Exit()
  914.  
  915.     elif 9 < evt < 20:
  916.         for i, k in enumerate(hot):
  917.            if i+10!=evt:
  918.                  hotkeys[k][-1].val=0
  919.                  UP=0 
  920.         Blender.Window.Redraw()
  921.  
  922.     elif 19 < evt < 46:
  923.         for i, k in enumerate(hotL):
  924.            if i+20!=evt:
  925.                  hotkeys['Letters '][0][k][-1].val=0
  926.                  UP=0 
  927.         Blender.Window.Redraw()
  928.  
  929.     elif (evt==up):
  930.        UP+=1
  931.        Blender.Window.Redraw()
  932.  
  933.     elif (evt==down):
  934.        if UP>0: UP-=1
  935.        Blender.Window.Redraw()
  936.  
  937.     elif (evt==LINE):
  938.        if SEARCHLINE.val!='' and SEARCHLINE.val!=OLDSEARCHLINE:
  939.           OLDSEARCHLINE=SEARCHLINE.val    
  940.           FINDED=searchfor(OLDSEARCHLINE)
  941.           Blender.Window.Redraw()
  942.  
  943. if __name__ == '__main__':
  944.     Register(draw, event, bevent)
  945.